Skip to content

docs: color palette aliases design decisions - #22

Merged
jackgranatowski merged 1 commit into
mainfrom
docs/color-aliases-design-decisions
May 19, 2026
Merged

docs: color palette aliases design decisions#22
jackgranatowski merged 1 commit into
mainfrom
docs/color-aliases-design-decisions

Conversation

@kiro-agent

@kiro-agent kiro-agent Bot commented May 19, 2026

Copy link
Copy Markdown

This pull request was created by @kiro-agent on behalf of @jackgranatowski 👻

Comment with /kiro fix to address specific feedback or /kiro all to address everything.
Learn about Kiro autonomous agent


Summary

Adds a design decisions document for the upcoming semantic color alias layer in tokens.palette.css.

Key decisions documented:

  • Extended numeric palette: 50-950 (11 steps, Tailwind-aligned)
  • Extended alpha scale: a5-a95 (11 steps, symmetric with edge densification)
  • 6 semantic shade aliases per brand color: superlight, xlight, lighter, darker, xdark, superdark
  • 5 functional aliases per brand color: hover, active, subtle, muted, ghost
  • Status colors mini-palette: 3 aliases each (subtle, muted, strong)
  • Remapping mechanism: aliases point to numeric tokens via var(), user overrides propagate globally

Open questions for review:

  1. Functional aliases (hover, active) vs existing --sf-color-bg--hover in core - different scope, confirm no confusion
  2. Status aliases vs existing --sf-status-{x}-bg/text/border - replace, alias, or coexist?
  3. 500 token implementation: literal var() reference or color-mix() for consistency?

No code changes - documentation only for team review before implementation.

Summary by CodeRabbit

  • Documentation
    • Added comprehensive design documentation for a color alias layer, outlining expanded palette scales, semantic and functional color options, status colors, and customization mechanisms for the design system.

Review Change Stack

Co-authored-by: Jack Granatowski <contact@codeslash.net>
@coderabbitai

coderabbitai Bot commented May 19, 2026

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

This PR adds a design document proposing a semantic color alias layer for SLASHED. The specification defines expanded numeric and alpha scales, shade and functional aliases per brand color, status color tokens, and a var()-based remapping mechanism to allow runtime overrides.

Changes

Color Alias Design Specification

Layer / File(s) Summary
Design specification and token architecture
docs/color-aliases-design-decisions.md
Proposes a new semantic color alias layer extending SLASHED's three-layer architecture. Defines numeric palette expansion (50/500/950), symmetric alpha scale (a5a95), shade aliases (superlight/xlight/lighter and darker/xdark/superdark), functional aliases (hover/active/subtle/muted/ghost) chained via var() to shades, status color mini-palette, placement in optional/tokens.palette.css, and a remapping mechanism for :root overrides. Includes token count estimates, industry inspiration sources, and open verification questions.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The pull request title accurately and concisely describes the main change: a documentation file adding design decisions for color palette aliases in a design system.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/color-aliases-design-decisions

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
docs/color-aliases-design-decisions.md (1)

177-179: ⚡ Quick win

Resolve token coexistence strategy before implementation handoff.

Line 178 leaves a core contract open (--sf-color-{status}-* vs --sf-status-{x}-bg/text/border). Add an explicit decision (replace, alias, or coexist) plus migration rule to avoid divergent implementations.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/color-aliases-design-decisions.md` around lines 177 - 179, Decide and
document a single coexistence strategy for the color-status tokens: explicitly
state whether `--sf-color-{status}-subtle/muted/strong` will replace, alias to,
or coexist with the existing `--sf-status-{x}-bg/text/border`, and add a clear
migration rule (e.g., "alias for N releases then replace", or "coexist with
priority order and deprecation timeline") so implementers know how to map
`--sf-status-{x}-bg/text/border` to `--sf-color-{status}-*`; also clarify the
rule for `500` palette values (literal `var(--sf-color-primary)` vs color-mix
pattern) and prescribe the canonical form to use across the palette to avoid
divergent implementations.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/color-aliases-design-decisions.md`:
- Around line 50-58: The markdown fence blocks that list the design token scale
(e.g., the block containing lines like "--sf-color-{color}-superlight → 50" and
the other similar blocks around the later color lists) are missing fence
languages and trigger MD040; update each fenced code block (the three blocks
that show the color scale and the other blocks covering the ranges mentioned) to
include a language tag such as "css" (e.g., replace ``` with ```css) so the code
fences are annotated for the linter.

---

Nitpick comments:
In `@docs/color-aliases-design-decisions.md`:
- Around line 177-179: Decide and document a single coexistence strategy for the
color-status tokens: explicitly state whether
`--sf-color-{status}-subtle/muted/strong` will replace, alias to, or coexist
with the existing `--sf-status-{x}-bg/text/border`, and add a clear migration
rule (e.g., "alias for N releases then replace", or "coexist with priority order
and deprecation timeline") so implementers know how to map
`--sf-status-{x}-bg/text/border` to `--sf-color-{status}-*`; also clarify the
rule for `500` palette values (literal `var(--sf-color-primary)` vs color-mix
pattern) and prescribe the canonical form to use across the palette to avoid
divergent implementations.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: df24b1a3-164c-4d82-b220-964299c99703

📥 Commits

Reviewing files that changed from the base of the PR and between efa6421 and 588b694.

📒 Files selected for processing (1)
  • docs/color-aliases-design-decisions.md

Comment on lines +50 to +58
```
--sf-color-{color}-superlight → 50
--sf-color-{color}-xlight → 200
--sf-color-{color}-lighter → 400
[base = 500 = --sf-color-{color}]
--sf-color-{color}-darker → 600
--sf-color-{color}-xdark → 800
--sf-color-{color}-superdark → 950
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Add fence languages to code blocks to satisfy markdown linting.

Line 50, Line 76, and Line 95 use fenced blocks without a language, which triggers MD040 and can fail doc CI in stricter setups. Please annotate them (e.g., css).

Also applies to: 76-82, 95-99

🧰 Tools
🪛 markdownlint-cli2 (0.22.1)

[warning] 50-50: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/color-aliases-design-decisions.md` around lines 50 - 58, The markdown
fence blocks that list the design token scale (e.g., the block containing lines
like "--sf-color-{color}-superlight → 50" and the other similar blocks around
the later color lists) are missing fence languages and trigger MD040; update
each fenced code block (the three blocks that show the color scale and the other
blocks covering the ranges mentioned) to include a language tag such as "css"
(e.g., replace ``` with ```css) so the code fences are annotated for the linter.

@jackgranatowski
jackgranatowski merged commit e109112 into main May 19, 2026
3 checks passed
@jackgranatowski
jackgranatowski deleted the docs/color-aliases-design-decisions branch May 31, 2026 18:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants